<h1>Listing items</h1>

<table>
  <tr>
    <th>Iditem</th>
    <th>Nomeitem</th>
    <th>Linkfoto</th>
  </tr>

<% @items.each do |item| %>
  <tr>
    <td><%=h item.idItem %></td>
    <td><%=h item.nomeItem %></td>
    <td><%=h item.linkfoto %></td>
    <td><%= link_to 'Show', item %></td>
    <td><%= link_to 'Edit', edit_item_path(item) %></td>
    <td><%= link_to 'Destroy', item, :confirm => 'Are you sure?', :method => :delete %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to 'New item', new_item_path %>